<div id="form_leave">
	<div class="pc-nav form-nav">
		<button @click="back(-1)"><i class="icon iconfont">&#xe62b;</i></button>
		<span>物品采购</span>
	</div>
	<form-repeat class="approval-form-repeat approval-form-wrap" v-on:getrepeat="repeatFn" init='[{"name":"物品名称","value":""},{"name":"规格型号","value":""},{"name":"单价(元)","value":""},{"name":"数量","value":""},{"name":"总价(元)","value":""},{"name":"用途","value":""}]' btntext="增加明细" title="明细" >
		 <template slot-scope="props">
			<li>
				<em class="left"><span style="color: red;">*</span>物品名称</em>
				<i class="right">
					<input  type="text" v-model="props.o[0].value" placeholder="请输入(必填)" />
				</i>
			</li>
			<li v-if="subFlag && /^\s*$/g.test(props.o[0].value)">
				<em class="left"></em>
				<i class="right">
					<p style="color: red;" data-false='true'>物品名称不能为空</p>
				</i>
			</li>
			<li>
				<em class="left">规格型号</em>
				<i class="right">
					<input  type="text" v-model="props.o[1].value"  />
				</i>
			</li>
			<li>
				<em class="left"><span style="color: red;">*</span>单价(元)</em>
				<i class="right">
					<input  type="number" v-model="props.o[2].value" placeholder="请输入(必填)" />
				</i>
			</li>
			<li v-if="subFlag && /^\s*$/g.test(props.o[2].value)">
				<em class="left"></em>
				<i class="right">
					<p style="color: red;" data-false='true'>单价(元)不能为空</p>
				</i>
			</li>
			<li>
				<em class="left"><span style="color: red;">*</span>数量</em>
				<i class="right">
					<input  type="number" v-model="props.o[3].value" placeholder="请输入(必填)" />
				</i>
			</li>
			<li v-if="subFlag && /^\s*$/g.test(props.o[3].value)">
				<em class="left"></em>
				<i class="right">
					<p style="color: red;" data-false='true'>数量不能为空</p>
				</i>
			</li>
			<li>
				<em class="left"><span style="color: red;">*</span>总价(元)</em>
				<i class="right">
					<input  type="number" v-model="props.o[4].value" placeholder="请输入(必填)" />
				</i>
			</li>
			<li v-if="subFlag && /^\s*$/g.test(props.o[3].value)">
				<em class="left"></em>
				<i class="right">
					<p style="color: red;" data-false='true'>总价(元)不能为空</p>
				</i>
			</li>
			<li>
				<em class="left">用途</em>
				<i class="right">
					<input  type="text" v-model="props.o[5].value"  />
				</i>
			</li>
			<li>
				<em class="left"></em>
				<i class="right">
					如有多个申购项请点击”增加明细“按钮
				</i>
			</li>
		</template>
	</form-repeat>
	<ul class="approval-form-wrap">
		<li>
			<em class="left"></em>
			<i class="right" >
				<span style="color: #CCCCCC;">总总价(元)</span>:{{ totalPrice }}
			</i>
		</li>
		<li>
			<em class="left">图片</em>
			<i class="right">
				<upload_tpl message="img" name="图片" v-on:getfile="getFilefn"></upload_tpl>
			</i>
		</li>
		<li>
			<em class="left">审批人</em>
			<i class="right">
				<dingding_users  v-on:getdingdinguser="getApproveUsers" message="approve" :approve_list="approve_list" :cc_list="cc_list" ></dingding_users>
			</i>
		</li>
		<li>
			<em class="left">抄送人</em>
			<i class="right">
				  <dingding_users v-on:getdingdinguser="getCopyUsers" :approve_list="approve_list" :cc_list="cc_list" message="cc"></dingding_users>
			</i>
		</li>
		<li>
			<em class="left"></em>
			<i class="right">
				  <span v-if="subFlag"></span>
				 <button class="submit-foot" @click="submitFn">提交</button>
			</i>
		</li>
	</ul>
</div>
